package com.qys.livesMall.anchor.mapper;


import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.qys.livesMall.anchor.model.entity.AnchorRewardConfig;

/**
 * 主播奖励配置(AnchorRewardConfig)表数据库访问层
 *
 * @author makejava
 * @since 2023-10-24 15:13:59
 */
public interface AnchorRewardConfigMapper extends BaseMapper<AnchorRewardConfig> {

    /**
     * 判断用户是否领取过某个奖励
     * @param conId
     * @param userId
     * @return
     */
    int rewardJudgment(Long conId, Long userId, boolean today);

    /**
     * 保存奖励记录
     * @param conId  奖励配置id
     * @param userId 用户id
     */
    void keepRecords(Long conId, Long userId);
}

